<template>
	<!-- 记账搜索框 -->
	<view class="jz-search">
		<u-search
			placeholder="请输入关键字"
			:modelValue="modelValue"
			@search="searchData"
			@custom="searchData"
			height="64"
		></u-search>
	</view>
</template>

<script lang="ts" setup>
defineProps({
	modelValue: {
		type: String,
		default: ""
	}
});
const emit = defineEmits<{
	(e: "update:modelValue", keyword: string): void;
}>();

const searchData = (e: string) => {
	emit("update:modelValue", e);
};
</script>

<style lang="scss" scoped>
.jz-search {
	height: 100rpx;
	line-height: 100rpx;
	background-color: #fff;
	padding: 0 30rpx;
	border-bottom: 1rpx solid #f4f4f4;
}
</style>
